import os

source = 'SplitShow.tex'

env = Environment(ENV = os.environ)
env.Append(BUILDERS = {'PDFOpen': Builder(action = 'open -a SplitShow $SOURCE', src_suffix = '.pdf')})

pdf = env.PDFOpen(env.PDF(source))

# clean out beamer-specific files
Clean(pdf, [source.rsplit('.',1)[0] + ext for ext in Split('.nav .out .snm .toc')])
